//package com.sskj.hiksdk;
//
//import cn.nkk.hikvision.utils.HkUtils;
//import org.springframework.web.bind.annotation.GetMapping;
//import org.springframework.web.bind.annotation.RequestMapping;
//import org.springframework.web.bind.annotation.RestController;
//
//import javax.servlet.AsyncContext;
//import javax.servlet.http.HttpServletRequest;
//import javax.servlet.http.HttpServletResponse;
//
///**
// * @Author: Like
// * @Date: 2024/12/19 14:31
// * @Description:
// */
//@RestController
//@RequestMapping("/test")
//public class TestController {
//    @GetMapping(value = "/video/rtspReal.flv",produces = {"video/x-flv;charset=UTF-8"})
//    public void flvRtspReal(HttpServletResponse response, HttpServletRequest request){
//
//        AsyncContext asyncContext = request.startAsync();
//        asyncContext.setTimeout(0);
//
//        String rtspUrl = HkUtils.toRtspUrl("192.168.88.161", "554", "admin", "Langhong@2023",101);
//        try {
//            HkUtils.rtspToFlv(rtspUrl,asyncContext);
//        }catch (Exception e){
//            e.printStackTrace();
//        }
//    }
//}
